home *** CD-ROM | disk | FTP | other *** search
/ 600 Games / 600games.iso / Puzzle / rebound.swf / scripts / frame_8 / PlaceObject2_302_225 / CLIPACTIONRECORD onClipEvent(enterFrame).as < prev    next >
Encoding:
Text File  |  2006-06-13  |  592 b   |  33 lines

  1. onClipEvent(enterFrame){
  2.    if(_root.dir == 1)
  3.    {
  4.       pxx = this._x;
  5.       pyy = this._y - sss;
  6.    }
  7.    else if(_root.dir == 2)
  8.    {
  9.       pxx = this._x - sss;
  10.       pyy = this._y;
  11.    }
  12.    else if(_root.dir == 3)
  13.    {
  14.       pxx = this._x;
  15.       pyy = this._y + sss;
  16.    }
  17.    else if(_root.dir == 4)
  18.    {
  19.       pxx = this._x + sss;
  20.       pyy = this._y;
  21.    }
  22.    if(_root.wall.hitTest(pxx,pyy,true))
  23.    {
  24.       _root.wallsoundbar();
  25.       _root.reboundcounts += 1;
  26.       _root.dir += 2;
  27.       if(_root.dir >= 5)
  28.       {
  29.          _root.dir -= 4;
  30.       }
  31.    }
  32. }
  33.